<?php

class Default_Model_Form_Message extends Zend_Form
{
    public function __construct($options = null)
    {
        parent::__construct($options);
        $this->setName('category');

        $name = new Zend_Form_Element_Text('name');
        $name->setLabel('Name of category:')
                    ->setRequired(true)
                    ->addFilter('StripTags')
                    ->addFilter('StringTrim')
                    ->addValidator('NotEmpty')
                    ->setAttrib('size', 30);

        $phone = new Zend_Form_Element_Text('phone');
        $phone->setLabel('Name of category:')
                ->setRequired(true)
                ->addFilter('StripTags')
                ->addFilter('StringTrim')
                ->addValidator('NotEmpty')
                ->setAttrib('size', 30);

        $mail = new Zend_Form_Element_Text('mail');
        $mail->setLabel('Name of category:')
            ->setRequired(true)
            ->addFilter('StripTags')
            ->addFilter('StringTrim')
            ->addValidator('NotEmpty')
            ->setAttrib('size', 30);

        $message = new Zend_Form_Element_Textarea('message');
        $message->setLabel('Text of module:')
            ->setRequired(true)
            ->addFilter('StringTrim')
            ->addValidator('NotEmpty')
            ->setAttrib('class', 'elrte');


        $submit = new Zend_Form_Element_Submit('submit');
        $submit->setAttrib('id', 'submitbutton');


        $this->addElements(array($name, $phone, $mail, $message, $submit));
    }
}